FROM adoptopenjdk:8-jre-openj9
LABEL maintainer=twinkle-leaf

# 安装tini
RUN curl -L -o /usr/local/bin/tini https://github.com/krallin/tini/releases/download/v0.19.0/tini-static-amd64 \
    && chmod +x /usr/local/bin/tini

ENV PARAMS="--server.port=8080 --spring.profiles.active=prod"
COPY target/*.jar /app.jar
ENTRYPOINT ["/usr/local/bin/tini", "--", "java","-jar", "-Xmx512m", "-Djava.security.egd=file:/dev/./urandom", "/app.jar"]

EXPOSE 8080
